import jsonschema
data = {"json_data":
    {
    "username": "小肥猪",
    "mobile": 18170039913,
    "workNumber": 517313
    },
    "status_code": 200,
    "success": True,
    "code": 10000,
    "message": "操作成功"
       }

schema = {"type":"object",
    "properties":{
    "json_data":{"type":"object",
    "properties":{
    "username":{"type":"string"},
    "mobile":{"pattern":"^[0-9]{11}$"},
    "workNumber":{"comst":9527}
                  }
                 }
                 },
    "required":["json_data","status_code","success","code","message"],
        }
print(jsonschema.validate(instance=data,schema=schema))